<!--
// +----------------------------------------------------------------------
// | Created by PHPstorm: JRKAdmin框架 [ JRKAdmin ]
// +----------------------------------------------------------------------
// | Copyright (c) 2019~2022 [LuckyHHY] All rights reserved.
// +----------------------------------------------------------------------
// | SiteUrl: http://www.luckyhhy.cn
// +----------------------------------------------------------------------
// | Author: LuckyHhy <jackhhy520@qq.com>
// +----------------------------------------------------------------------
// | Date: 2020/3/4-17:10
// +----------------------------------------------------------------------
// | Description:
// +----------------------------------------------------------------------
*-->

{extend name='public/window' /}


{block name="content"}

<div class="layui-fluid">
    <div class="layui-card">
        <!-- <div class="layui-card-header"></div>-->

        <div class="layui-card-body" style="padding: 15px;">
            <form class="layui-form" action="" lay-filter="component-form-group">

                {lv:inputform  name="name" place="请输入网站名称" label="网站名称：" verify="required" class="name" /}

                {lv:inputform  name="href" place="网站地址需 http://" label="网站地址：" verify="required|url" class="href" /}

                {lv:inputform  name="email" place="站长邮箱" label="网站地址："  class="email" /}

                <div class="layui-form-item">
                    <label class="layui-form-label">所属分类：</label>
                    <div class="layui-input-block">
                        <select name="type"  class="link" lay-filter="link">
                            <option value="1" >优秀个人博客</option>
                            <option value="2">站长推荐</option>

                        </select>
                    </div>
                </div>

                <div class="layui-form-item">
                    <label class="layui-form-label">是否显示：</label>
                    <div class="layui-input-block">
                        <select name="status" class="userGrade" lay-filter="userGrade">
                            <option value="1" >显示</option>
                            <option value="0">不显示</option>

                        </select>
                    </div>
                </div>

                {:widget('common/forms/submit',array('add','立即提交',2))}

            </form>
        </div>
    </div>
</div>



<script>
    layui.use(['element', 'form', 'jquery','lucky'], function () {
        var element = layui.element;
        var table = layui.table;
        var form = layui.form;
        var $ = layui.jquery;
        var lucky=layui.lucky;


        form.on('submit(add)', function (data) {
            lucky.FormSubmit("{:url('friendlink/addFriend')}",data.field,"table_id",1);
            return false;
        });
    })
</script>

{/block}

